1. Field of the Invention
The present invention generally relates to communication networks, and more particularly, to packet networks for carrying information between hosts such as computers.
2. Related Art
Computer networks are often described with the aid of layered reference models for depicting the movement of information between host computers connected to the network. The layers help to segregate information and network functions into manageable units. The general functions of each layer are often based on an international standard called Open System Interconnection (OSI). OSI sets forth seven processing layers through which information may pass when received by a host in order to be presentable to a non-user. Similar, transmission of information from a host to the network may pass through those seven processing layers in reverse order.
Another layered reference model that is widely implemented is called TCP/IP (Transmission Control Protocol/Internet Protocol). A more complete definition of TCP/IP is given in RFC793, “Transmission Control Protocol”, and RFC791, “Internet Protocol”, published by the Defense Advanced Research Projects Agency (DARPA), hereby incorporated by reference.
A TCP/IP connection is managed by TCP, which uses sequence numbers, a maximum segment size (MSS), and a sliding window as flow control mechanisms.
When a TCP/IP connection is established, both the client and server transmit their respective 32-bit initial sequence numbers (ISN) as well as a maximum segment size (MSS). The server acknowledges receipt of the client's data by sending an acknowledge (ACK) to the client. Establishing a connection allows the client to send a segment of data to the server. A segment includes one or more packets. The beginning of the client's segment is referenced by the client's ISN. The server is responsible for acknowledging segments by sending an acknowledge number equal to the client's ISN plus the length of the contiguous data received.
During connection establishment, the server opens a “window” allowing the client to send up to the number of bytes of data specified by that window to the server. The maximum number of bytes sent per data packet is defined by the MSS. The relative positions of the payload bytes within a packet is defined by the sequence number of the packet.
When packets are received out-of-order, the server is expected to reassemble the packets into a contiguous stream, using the sequence number of each packet as an index. The server is also expected to acknowledge the client properly.
In many networked devices running TCP or other similar transport protocols, this reassembly process is carried out in software, using linked list data structures to check for contiguity. Software approaches for reassembling and parsing contiguous packets are useful in some applications. However, conventional software implementations sometimes lack the necessary speed and performance for other applications. Thus, there is a need for an improved approach to the function of packet reassembly and parsing in a packet switched network.